# === Basics ===
CC       = icc
CXX      = icpc
LD       = icpc
AR       = /usr/bin/ar
RANLIB   = ranlib

MPI_HOME = /sw/keeneland/openmpi/1.5.1/centos5.5_intel11.1.073

CPPFLAGS += -I/sw/keeneland/cuda/4.0/linux_binary/include
CFLAGS   += -m64 -g -O2 -openmp
CXXFLAGS += -m64 -g -O2 -openmp
NVCXXFLAGS += -m64 -g -O2
ARFLAGS  = rcv
LDFLAGS  = 
LIBS     = -lrt

USE_MPI         = yes
MPICXX          = ${MPI_HOME}/bin/mpicxx

# === CUDA Specific Flags ===
NVCC            = /sw/keeneland/cuda/4.0/linux_binary/bin/nvcc
CUDA_CXX        = /sw/keeneland/cuda/4.0/linux_binary/bin/nvcc
CUDA_INC        = -I/sw/keeneland/cuda/4.0/linux_binary/include -I$(MPI_HOME)/include
CUDA_CPPFLAGS   += -gencode=arch=compute_20,code=compute_20 -I${SHOC_ROOT}/src/cuda/include

USE_CUDA        = yes
ifeq ($(USE_CUDA),yes)
CUDA_LIBS       := $(shell /sw/keeneland/cuda/4.0/linux_binary/bin/nvcc -dryrun bogus.cu 2>&1 | grep LIBRARIES | sed 's/^.*LIBRARIES=//')
else
CUDA_LIBS       =
endif

